package com.lyfei.yd.system.domain.vo;

import com.lyfei.yd.system.domain.entity.SpecKey;
import com.lyfei.yd.system.domain.entity.SpecValue;
import lombok.Data;
import org.springframework.beans.BeanUtils;

import java.util.List;

@Data
public class SpecKeyAndItemsVo {
    private Integer id;

    private String name;

    private String unit;

    private Integer standard;

    private String description;

    private List<SpecValue> items;

    public SpecKeyAndItemsVo(SpecKey specKey, List<SpecValue> items) {
        BeanUtils.copyProperties(specKey, this);
        this.setItems(items);
    }
}
